package com.ruoyi.merchant.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.merchant.mapper.MerchantCouponBindingsMapper;
import com.ruoyi.merchant.domain.MerchantCouponBindings;
import com.ruoyi.merchant.service.IMerchantCouponBindingsService;

/**
 * 商家优惠券绑定Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-10-23
 */
@Service
public class MerchantCouponBindingsServiceImpl implements IMerchantCouponBindingsService 
{
    @Autowired
    private MerchantCouponBindingsMapper merchantCouponBindingsMapper;

    /**
     * 查询商家优惠券绑定
     * 
     * @param bindingId 商家优惠券绑定主键
     * @return 商家优惠券绑定
     */
    @Override
    public MerchantCouponBindings selectMerchantCouponBindingsByBindingId(String bindingId)
    {
        return merchantCouponBindingsMapper.selectMerchantCouponBindingsByBindingId(bindingId);
    }

    /**
     * 查询商家优惠券绑定列表
     * 
     * @param merchantCouponBindings 商家优惠券绑定
     * @return 商家优惠券绑定
     */
    @Override
    public List<MerchantCouponBindings> selectMerchantCouponBindingsList(MerchantCouponBindings merchantCouponBindings)
    {
        return merchantCouponBindingsMapper.selectMerchantCouponBindingsList(merchantCouponBindings);
    }

    /**
     * 新增商家优惠券绑定
     * 
     * @param merchantCouponBindings 商家优惠券绑定
     * @return 结果
     */
    @Override
    public int insertMerchantCouponBindings(MerchantCouponBindings merchantCouponBindings)
    {
        return merchantCouponBindingsMapper.insertMerchantCouponBindings(merchantCouponBindings);
    }

    /**
     * 修改商家优惠券绑定
     * 
     * @param merchantCouponBindings 商家优惠券绑定
     * @return 结果
     */
    @Override
    public int updateMerchantCouponBindings(MerchantCouponBindings merchantCouponBindings)
    {
        return merchantCouponBindingsMapper.updateMerchantCouponBindings(merchantCouponBindings);
    }

    /**
     * 批量删除商家优惠券绑定
     * 
     * @param bindingIds 需要删除的商家优惠券绑定主键
     * @return 结果
     */
    @Override
    public int deleteMerchantCouponBindingsByBindingIds(String[] bindingIds)
    {
        return merchantCouponBindingsMapper.deleteMerchantCouponBindingsByBindingIds(bindingIds);
    }

    /**
     * 删除商家优惠券绑定信息
     * 
     * @param bindingId 商家优惠券绑定主键
     * @return 结果
     */
    @Override
    public int deleteMerchantCouponBindingsByBindingId(String bindingId)
    {
        return merchantCouponBindingsMapper.deleteMerchantCouponBindingsByBindingId(bindingId);
    }
}
